package com.es.utils;

import org.apache.commons.beanutils.BeanUtils;

import java.util.HashMap;
import java.util.Map;

/**
 * Description:
 *
 * @Author: future
 * @Date:2022/12/5:17:39
 */
public class CommonUtil {

    public static Map<String, String> bean2Map(Object bean) {
        try {
            return BeanUtils.describe(bean);
        } catch (Exception e) {
            e.printStackTrace();
        }
        return new HashMap<>();
    }
}
